package org.qiancizhan.Utils;

public class UIFormatUtli {
    public static String HR = "-----------------------------------------------------------";

    public static void clearConsole() {
        try {
            System.out.print("\033[H\033[2J");
            System.out.flush();
            final String os = System.getProperty("os.name").toLowerCase();
            new ProcessBuilder("cmd", "/c", "cls").inheritIO().start().waitFor();
            for (int i = 0; i < 50; i++)
                System.out.println();
            System.out.println("欢迎来到千词斩!");

        } catch (final Exception e) {
            for (int i = 0; i < 50; i++)
                System.out.println();
            System.out.println("欢迎来到千词斩!");

        }
    }
    public static void log(String str){
        System.out.println(UIFormatUtli.HR);
        System.out.println(str);
    }
}
